#ifndef SCRIPTAPPLICATION_H
#define SCRIPTAPPLICATION_H

#include <QApplication>
class Workbench;

class ScriptApplication : public QApplication
{
    Q_OBJECT
    Q_PROPERTY(QString user READ getUser WRITE setUser)
    Q_PROPERTY(QString password READ getPassword WRITE setPassword)
    Q_PROPERTY(QString os READ os)

public:
    ScriptApplication(int argc, char *argv[]);
    ~ScriptApplication();
    void loadProject(const QString& projectFile = QString());

    QString getUser() { return m_user; }
    void setUser(const QString &user) { m_user = user; }

    QString getPassword() { return m_password; }
    void setPassword(const QString &password) { m_password = password; }

    Q_INVOKABLE QString os(){ return m_osName; }
    Q_INVOKABLE void debug();
    Q_INVOKABLE void about();

private:
    Workbench* m_workbench;
    QString m_user;
    QString m_password;
    QString m_osName;
};

#endif // SCRIPTAPPLICATION_H
